package fr.afcepf.ai85.ent;

// Generated 21 mars 2013 17:20:56 by Hibernate Tools 3.4.0.CR1

import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * MessageEnvoye generated by hbm2java
 */
@Entity
@Table(name = "message_envoye", catalog = "gepeto_db")
public class MessageEnvoye implements java.io.Serializable {

	private Integer idMessageEnvoye;
	private Eleve eleve;
	private String objetMessageEnv;
	private String messageEnv;
	private Date dateMessageEnv;

	public MessageEnvoye() {
	}

	public MessageEnvoye(Eleve eleve) {
		this.eleve = eleve;
	}

	public MessageEnvoye(Eleve eleve, String objetMessageEnv,
			String messageEnv, Date dateMessageEnv) {
		this.eleve = eleve;
		this.objetMessageEnv = objetMessageEnv;
		this.messageEnv = messageEnv;
		this.dateMessageEnv = dateMessageEnv;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "ID_MESSAGE_ENVOYE", unique = true, nullable = false)
	public Integer getIdMessageEnvoye() {
		return this.idMessageEnvoye;
	}

	public void setIdMessageEnvoye(Integer idMessageEnvoye) {
		this.idMessageEnvoye = idMessageEnvoye;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "ID_ELEVE", nullable = false)
	public Eleve getEleve() {
		return this.eleve;
	}

	public void setEleve(Eleve eleve) {
		this.eleve = eleve;
	}

	@Column(name = "OBJET_MESSAGE_ENV", length = 100)
	public String getObjetMessageEnv() {
		return this.objetMessageEnv;
	}

	public void setObjetMessageEnv(String objetMessageEnv) {
		this.objetMessageEnv = objetMessageEnv;
	}

	@Column(name = "MESSAGE_ENV")
	public String getMessageEnv() {
		return this.messageEnv;
	}

	public void setMessageEnv(String messageEnv) {
		this.messageEnv = messageEnv;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "DATE_MESSAGE_ENV", length = 10)
	public Date getDateMessageEnv() {
		return this.dateMessageEnv;
	}

	public void setDateMessageEnv(Date dateMessageEnv) {
		this.dateMessageEnv = dateMessageEnv;
	}

}
